﻿<%@ Page Title="" Language="C#" MasterPageFile="~/Presentacion/TourMaster.master" AutoEventWireup="true" CodeBehind="API_tour_BuscarHotel.aspx.cs" Inherits="UricaoWeb.Presentacion.API_tour_BuscarHotel" %>
<asp:Content ID="Content1" ContentPlaceHolderID="ContenidoDelModuloTour" runat="server">

     <form id="Tours" role="form" runat="server" >

    <h2>B&uacute;squeda de hotel(es) </h2>
    
    

        <div id="Div1" role="search" class="searchForm" runat="server">
            <asp:TextBox ID="InputBuscar" runat="server" 
                        AutoPostBack="True" 
                        EnableTheming="False" 
                        CssClass="inputPersonalizado"
                        OnTextChanged="BuscadorTextChanged"   
                        Height="25px" Width="450px"
                        placeholder=" Buscar hotel">
            </asp:TextBox>
            <asp:ImageButton id="btnSearch" 
                             runat="server"
                             OnClick="BuscadorTextChanged" 
                             ImageUrl="images/glyphicons_search.png" 
                             CssClass=" botonCualquiera btnSearch"/>
        </div>

            <br />
            <br />
        <div>
            <asp:ScriptManager ID="ScriptManager1" runat="server">
            </asp:ScriptManager>
        </div>
     
        <div id="Datos"  role="form" runat="server">
            <asp:MultiView ID="MvListaHoteles" runat="server" ActiveViewIndex="0">
                <!-- Gridview con Ajax -->
                <asp:View ID="GvOrdenHoteles" runat="server">
                    <asp:UpdatePanel ID="UpdatePanel1" runat="server">
                        <ContentTemplate>
                            <asp:GridView ID="GvHoteles" CssClass="mGrid" runat="server" BorderStyle="None"  AllowSorting="true"
                                            GridLines="None" AutoGenerateColumns="False" AllowPaging="True"  PageSize="2"
                                            DataKeyNames="idHotel" 
                                            OnSelectedIndexChanged="GvSelectedIndexChanged" 
                                            OnPageIndexChanging="GvPageIndexChanging"
                                             >
                                <Columns>
                                    <asp:BoundField HeaderText="Nombre" DataField="nombreHotel" ItemStyle-Width="150px" ItemStyle-VerticalAlign="Middle"></asp:BoundField>
                                    <asp:BoundField HeaderText="Descripción" DataField="descripcionHotel" ItemStyle-Width="290px" ItemStyle-VerticalAlign="Middle"></asp:BoundField>
                                    <asp:BoundField HeaderText="Posición" DataField ="estrellaHotel" ItemStyle-HorizontalAlign="Center" ItemStyle-VerticalAlign="Middle"></asp:BoundField>
                                    <asp:BoundField HeaderText="Dirección" DataField="direccionHotel" ItemStyle-HorizontalAlign="Center" ItemStyle-VerticalAlign="Middle"></asp:BoundField>
                                   
                                         <asp:CommandField HeaderText="Acciones"
                                            ShowSelectButton="True" ButtonType="Image" ItemStyle-HorizontalAlign="Center"  
                                            SelectImageUrl="images/glyphicons_eye_open.png" 
                                            ItemStyle-VerticalAlign="Middle"
                                         />
                                </Columns>
                                <PagerSettings Mode="Numeric" Position="Bottom"  PageButtonCount="5"/>
                                <pagerstyle backcolor="LightBlue"
                                                height="30px"
                                                VerticalAlign="Middle"
                                                horizontalalign="Center"  />
                            </asp:GridView>
                        </ContentTemplate>
                    </asp:UpdatePanel>
                    <asp:UpdateProgress ID="UpdateProgress1" runat="server">
                        <ProgressTemplate>
                            <br/>
                            Cargando ...
                        </ProgressTemplate>
                    </asp:UpdateProgress>

                </asp:View>
                    

            </asp:MultiView>
        </div>
    
    <br/><br/>
    </form>

</asp:Content>
